| Name | Item Components |
| Description | Minecraft item components (see https://minecraft.wiki/w/Data_component_format) are managed as follows:
Each item type has a default set of component values; a food item will have food components by default, a tool item will have tool components by default, etc. Different items can override their type's default components, either by setting values that weren't there previously (e.g. making an inedible item edible), or by removing values that are there by default (e.g. making a shield item that can't block). Items' overrides can later be reset, making them use their type's default values again. In Denizen, different item components are represented by item properties. These properties allow both setting a component override on an item, and clearing/resetting it by providing no input. Item properties' name will generally match their respective item component's name, but not always! Due to this, features that take item component names as input (such as ItemTag.is_overridden) accept both Minecraft component names and Denizen property names. Here is an example of applying all of this in a script: |
| Group | Minecraft Logic |
| Source | https://github.com/DenizenScript/Denizen/blob/dev/paper/src/main/java/com/denizenscript/denizen/paper/datacomponents/DataComponentAdapter.java#L25 |